﻿using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using TSqlServer;

public partial class ajax_forum_list : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            string topicid = Request["topicid"].ToString();
            DisplayForum(topicid);
        }
    }

    private void DisplayForum(string TopicID)
    {
        string sSql = "select dbo.getbignamebyid(forum_author) as forum_author,forum_time,forum_content from t_bbs_forum where forum_tid='" + TopicID + "' and forum_flag=0 order by forum_time";
        TSqlDBReader myReader = new TSqlDBReader(sSql);
        dlForum.DataSource = myReader.FDataReader;
        dlForum.DataBind();
        //关闭
        myReader.Free();

    }
}
